extends "../suweiailuoxiya-2/suweiailuoxiya-2.gd"

func _extInit():
	._extInit()
	lv = 3             #等级的设置
	addSkill("碧蓝航线阵营的友军发起炮击时，立即对该目标支援一次炮击(内置冷却1秒)", "联合打击")

func onBattleStartEx():
	.onBattleStartEx()
	for i in getAllChas(2):
		if i.get("camp") == "碧蓝航线" and i.ename != ename:
			castBuff(i, b_sovetskaya2.new())

var enableSk4 = true
func _upS():
	._upS()
	enableSk4 = true

#联合打击
class b_sovetskaya2:
	extends "../../../azurlane_ctrl/AzurBuff.gd"
	func _init():
		attInit()
		buffName = "联合打击"
		dispel = 2
		id = "b_sovetskaya2"
	func _connect():
		if masCha.chaName.find("苏维埃罗西亚") == -1:
			masCha.connect("onAtkChara",self,"run")
	func run(atkInfo):
		if atkInfo.atkType == sys.AtkType.GUN and not casCha.isDeath and casCha.enableSk4:
			casCha.normalAtkChara(atkInfo.hitCha)
			casCha.enableSk4 = false
	